package tv.drplay.course.ui.splash

import android.content.Intent
import top.kpromise.ibase.base.BaseViewModel
import top.kpromise.ibase.base.IBaseActivity
import tv.drplay.course.R
import tv.drplay.course.databinding.SplashView

class SplashActivity: IBaseActivity<SplashView>() {

    override fun layoutId(): Int {
        return R.layout.activity_splash
    }

    override fun cancelCreate(): Boolean {
        if (intent.flags and Intent.FLAG_ACTIVITY_BROUGHT_TO_FRONT != 0) {
            return true
        }
        return false
    }

    override fun viewModel(): BaseViewModel? {
        return SplashVm()
    }
}